table.insert(itemActions,
	function(item, action)
		-- RARE jewels
		-- see: dir .. "readme.txt" for information regarding these variables
		local priority = 5
		local identify = true --set to false to keep ALL rare jewels
		local dump = false

		-- rare jewel functions not written yet. Currently just checks against magic\jewels.lua
		if not (item.quality == ItemQuality.Rare and item.baseItem.code == "jew") then
			return false
		elseif action == aPICK and  (not item.flags.Identified or isGoodMagicJewel(item)) then
			return priority
		elseif action == aIDENT then
			return identify
		elseif action == aSELL  and item.flags.Identified and not isGoodMagicJewel(item) then
			 return true
		elseif action == aDUMP and item.flags.Identified and not isGoodMagicJewel(item) then
			return dump
		end
		return false
	end
)